package designpatterns.decorator;

import org.junit.Test;

/**
 * @author LiDong
 * @version 1.0.0
 * @createTime 2022/2/14 8:45
 */
public class AppTest {

    @Test
    public void test() {
        Shape circle = new Circle();
        ShapeDecorator redCircle = new RedShapeDecorator(new Circle());
        ShapeDecorator redRectangle = new RedShapeDecorator(new Rectangle());

        circle.draw();
        redCircle.draw();
        redRectangle.draw();
    }
}
